package com.xuerhua.yxt.baidu.model;

import java.io.Serializable;

import org.codehaus.jackson.annotate.JsonIgnoreProperties;

import com.xuerhua.yxt.baidu.aip.ErrorCode;
/**
 * 人脸检测
 * @author hqm
 *
 */
@JsonIgnoreProperties(ignoreUnknown = true)
public class AipFaceDetect implements Serializable{

	private static final long serialVersionUID = 1441779217244765932L;
	
	//人脸结果
	private FaceDetectResult result;
	
	private Long log_id;
	
	private int cached;
	//错误码 值为0代表图片检测没问题
	private String error_code;
	//错误描述
	private String error_msg;
	//时间
	private Long timestamp;
	
	private String fileUrl;
	
	public FaceDetectResult getResult() {
		return result;
	}
	public void setResult(FaceDetectResult result) {
		this.result = result;
	}
	public Long getLog_id() {
		return log_id;
	}
	public void setLog_id(Long log_id) {
		this.log_id = log_id;
	}
	public int getCached() {
		return cached;
	}
	public void setCached(int cached) {
		this.cached = cached;
	}
	public String getError_code() {
		return error_code;
	}
	public void setError_code(String error_code) {
		this.error_code = error_code;
	}
	public String getError_msg() {
		return error_msg;
	}
	public void setError_msg(String error_msg) {
		this.error_msg = error_msg;
	}
	public Long getTimestamp() {
		return timestamp;
	}
	public void setTimestamp(Long timestamp) {
		this.timestamp = timestamp;
	}
	public String getErrorDesc() {
		String result = ErrorCode.getErrorDesc(error_code);
		if(result == null) return error_msg;
		return result;
	}
	public String getFileUrl() {
		return fileUrl;
	}
	public void setFileUrl(String fileUrl) {
		this.fileUrl = fileUrl;
	}
	
}
